<template>
  <!-- testimonials -->
  <section class="testimonials py-5">
  	<div class="container  py-md-3" >
  			<h3 class="heading text-capitalize text-center mb-lg-5 mb-4">{{data.title}}</h3>
			<div style="text-align: center;">
				<p v-html="data.content"></p>
			</div>
  		<div class="row py-5">
  			<div class="col-md-4 test-grid px-lg-5" v-for="(item,index) in data.articleList">
  				<div class="testi-info text-center">
  					<div class=" text-center mt-4">
  						<img :src="item.imgUrl" class="img-fluid" alt="user-image">
  					</div>
  					<h3 class="mt-md-4 mt-3">
						<a :href="item.abstractContent" target="_blank">{{item.title}}</a>
					</h3>
					<p class="text-li">
						<p v-html="item.content"></p>
					</p>
  				</div>
  			</div>
  		</div>
  	</div>
  </section>
  <!-- //testimonials -->
</template>
<script>
	import api from "@/api/index"

	export default {
		data(){
			return {
				data:{},
				id:0
			}
		},
		mounted() {
			this.getChildAndArticle(this.$route.query.classId)
		},
		methods:{
			//获取数据
			async getChildAndArticle(classId) {
				var url='?id='+classId
				api.getChildAndArticle(url).then(res => {
					this.data=res.data.data[0]
				})
			},
			
		}
	}
</script>

